/* component/mMediaShow/index.wxss */
.m-media-show {
  &:after {
    content: '';
    display: block;
    clear: both;
  }
  .item {
    position: relative;
    float: left;
    margin: 0 16rpx 16rpx 0;
    width: 160rpx;
    height: 160rpx;
    overflow: hidden;
    &.upload {
      background: #F7F8FA;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
    }
    &.image {
      display: flex;
      align-items: center;
      justify-content: center;
      .icon {
        display: block;
        height: 100%;
      }
    }
    &.video {
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .close-btn {
      position: absolute;
      z-index: 2;
      top: 0;
      right: 0;
      width: 28rpx;
      height: 28rpx;
      background-color: rgba(0, 0, 0, 0.7);
      border-radius: 0 0 0 24px;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      .icon {
        position: absolute;
        top: -6rpx;
        right: -4rpx;
        color: #fff;
        font-size: 32rpx;
        transform: scale(0.5);
      }
    }
  }
}

.preview-video {
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #000;
  display: flex;
  align-items: center;
  animation: showPreive .3s;
  .close-btn {
    position: absolute;
    z-index: 100;
    top: 200rpx;
    right: 30rpx;
    width: 40rpx;
    height: 40rpx;
    &:before, &:after {
      content: '';
      position: absolute;
      top: 50%;
      left: 0;
      margin-top: -2rpx;
      width: 100%;
      height: 4rpx;
      background: #fff;
    }
    &:before {
      transform: rotate(45deg);
    }
    &:after {
      transform: rotate(-45deg);
    }
  }
  .video {
    width: 100%;
  }
}
@keyframes showPreive {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}
